 package com.bmps.springcloud.insuredmicroservice.model.accept.resquest;

 import org.apache.commons.lang3.builder.EqualsBuilder;
 import org.apache.commons.lang3.builder.HashCodeBuilder;

 import javax.validation.Valid;
 import javax.validation.constraints.NotNull;
 import java.io.Serializable;

 /**
  *  @author lyw
  *  @date 2019/07/24
  */
 public class CustInfoModel implements Serializable {
     @Valid
     @NotNull(message="appnt节点不能为空!")
	 private AppntModel appnt;

     @Valid
     @NotNull(message="insurants节点不能为空!")
	 private InsurantsModel insurants;

     @Valid
	 private BnfInfoModel bnfInfo;

     public AppntModel getAppnt() {
         return appnt;
     }

     public void setAppnt(AppntModel appnt) {
         this.appnt = appnt;
     }

     public InsurantsModel getInsurants() {
         return insurants;
     }

     public void setInsurants(InsurantsModel insurants) {
         this.insurants = insurants;
     }

     public BnfInfoModel getBnfInfo() {
         return bnfInfo;
     }

     public void setBnfInfo(BnfInfoModel bnfInfo) {
         this.bnfInfo = bnfInfo;
     }

     @Override
     public boolean equals(Object o) {
         if (this == o) {
             return true;
         }

         if (o == null || getClass() != o.getClass()) {
             return false;
         }

         CustInfoModel that = (CustInfoModel) o;

         return new EqualsBuilder()
                 .append(appnt, that.appnt)
                 .append(insurants, that.insurants)
                 .append(bnfInfo, that.bnfInfo)
                 .isEquals();
     }

     @Override
     public int hashCode() {
         return new HashCodeBuilder(17, 37)
                 .append(appnt)
                 .append(insurants)
                 .append(bnfInfo)
                 .toHashCode();
     }

     @Override
     public String toString() {
         return "CustInfoModel{" +
                 "appnt=" + appnt +
                 ", insurants=" + insurants +
                 ", bnfInfo=" + bnfInfo +
                 '}';
     }
 }
